home *** CD-ROM | disk | FTP | other *** search
/ Power Programmierung / Power-Programmierung (Tewi)(1994).iso / magazine / compute / 1989_02 / era.doc < prev    next >
Text File  |  1988-11-18  |  4KB  |  157 lines

  1.  
  2.                                     ERA
  3.                       A Replacement for the DEL Command
  4.                                  27 Aug 88
  5.  
  6.                         Program by Dennis Vallianos
  7.                              Notes by Irv Hoff
  8.  
  9.  
  10. ERA.COM is an MS-DOS "delete file(s)" program.  Unlike the normal DEL
  11. command, it shows the names of the files that will be deleted, then
  12. asks if you really want to erase them.
  13.  
  14. If a 'c' (for confirm) is appended to the command line, ERA will display
  15. the files matching the command line individually, then ask if you really
  16. want to erase each file.
  17.  
  18.  
  19. HOW TO USE ERA
  20.  
  21. First, copy ERA.COM to a directory that is in your current PATH statement.
  22. ERA does not accept drive specifications, and will only work in the
  23. current drive and directory.  If it is in a directory named in your PATH
  24. statement, you can use it in any directory.  Floppy disk users should
  25. copy ERA.COM to their normal DOS disk.
  26.  
  27. You can use ERA by entering one of the following commands.  Notice the
  28. wildcard filename.  Use *.* to indicate all files in the current
  29. directory.
  30.  
  31.        1.       ERA *.TXT
  32.  
  33.        2.       ERA *.TXT C
  34.  
  35.        The first example is for normal use.  It shows the names of
  36.        all files with a .TXT extent, then asks if it's OK to erase
  37.        those files.
  38.  
  39.        The second example shows the files one-at-a-time and asks
  40.        if you want to erase each file.
  41.  
  42.                (See below for an actual example)
  43.  
  44.  
  45. This very short (636 bytes) program has the tremendous advantage of
  46. allowing the user to SEE what will be erased and then verifying
  47. the command before erasing the files. This is a terrific advantage over
  48. the usual DEL command.
  49.  
  50.  
  51. EXAMPLE of its usefulness:
  52. --------------------------
  53.     Recently I erased the entire UTIL directory of some 123 files,
  54.     when I "thought" I was in another subdirectory where I did
  55.     want to erase the entire contents (all three files).  I gave the
  56.     command:
  57.  
  58.                         DEL *.*
  59.  
  60.     THEN discovered I was in UTIL and those files were GONE.
  61.     Fortunately, I had a back up that was reasonably current,
  62.     but what a nuisance!
  63.  
  64.  
  65.  
  66.  
  67.  
  68.  
  69.  
  70.  
  71. INSTALLING ERA.COM
  72. -------------------
  73.  
  74.         Just copy ERA.COM into in your UTIL or DOS directory.
  75.         Make sure the directory chosen is in your PATH
  76.         statement.  Now, instead of entering DEL to delete a
  77.         file, just enter ERA instead.  If you enter DEL, you
  78.         can still use the original DOS command.
  79.  
  80. DEMO of ERA
  81. -----------
  82.  
  83. Let's take a look at a simulated session with ERA.  For the purposes
  84. of this simulation, assume there is a directory, named \UU on drive C:.
  85. Read along, pretending that you are entering the commands shown.
  86. Remember, ERA.COM must be in a directory contained in your PATH statement.
  87.  
  88.    C:\UU>dir
  89.  
  90.     Volume in drive C has no label
  91.     Directory of  C:\UU
  92.  
  93.    ABIWI    TXT      636   8-27-88   4:44p
  94.    BIW33I   TXT      636   8-27-88   4:44p
  95.    AGIWI8SK TXT      636   8-27-88   4:44p
  96.    A238BDL  TXT      636   8-27-88   4:44p
  97.    A82CKSW  TXT      636   8-27-88   4:44p
  98.    AIBIS    TXT      636   8-27-88   4:44p
  99.            6 File(s)  11857920 bytes free
  100.  
  101.    C:\UU>era *.TXT
  102.  
  103.    ABIWI   .TXT   BIW33I  .TXT   SGIWI8SK.TXT   A238BDL .TXT   A82CKSW .TXT
  104.    AIBIS   .TXT     
  105.  
  106.    Ok to erase? y
  107.  
  108.    C:\UU>
  109.    C:\UU>era *.txt c
  110.  
  111.    Press Y to delete, N to skip, ESC to stop.
  112.  
  113.    Delete ABIWI   .TXT? No
  114.    Delete BIW33I  .TXT? Yes
  115.    Delete SGIWI8SK.TXT? Yes
  116.    Delete A238BDL .TXT? Yes
  117.    Delete A82CKSW .TXT? No
  118.    Delete AIBIS   .TXT? Yes
  119.  
  120.    No more matching files.
  121.  
  122.    C:\UU>dir *.txt     <<-- (just to show what's left)
  123.  
  124.  
  125.  
  126.  
  127.  
  128.  
  129.  
  130.  
  131.  
  132.  
  133.  
  134.  
  135.  
  136.     Volume in drive C has no label
  137.     Directory of  C:\UU
  138.  
  139.    ABIWI    TXT      636   8-27-88   4:44p
  140.    A82CKSW  TXT      636   8-27-88   4:44p
  141.            2 File(s)  11866112 bytes free
  142.  
  143.    C:\UU>era *.txt      <<-- normal use of ERA
  144.  
  145.    ABIWI   .TXT   A82CKSW .TXT
  146.  
  147.    Ok to erase?y
  148.  
  149.    C:\UU>dir *.txt
  150.  
  151.     Volume in drive C has no label
  152.     Directory of  C:\UU
  153.  
  154.     File not found
  155.  
  156.    C:\UU>
  157.